﻿using System;

namespace Creventive.Wpf.ShellFactory.Modules
{
    /// <summary>
    /// Registers the application module type.
    /// </summary>
    [AttributeUsage(AttributeTargets.Assembly, AllowMultiple = false)]
    public class ApplicationModuleAttribute : Attribute
    {
        private readonly Type moduleType;

        /// <summary>
        /// Initializes a new instance of the <see cref="ApplicationModuleAttribute"/> class.
        /// </summary>
        /// <param name="moduleType">Type of the module.</param>
        public ApplicationModuleAttribute(Type moduleType)
        {
            this.moduleType = moduleType;
        }

        /// <summary>
        /// Gets the type of the module.
        /// </summary>
        /// <value>The type of the module.</value>
        public Type ModuleType
        {
            get { return this.moduleType; }
        }
    }
}